package actions.manager;

import java.util.ArrayList;
import java.util.List;

import veilingDomein.Bieding;
import veilingDomein.Veiling;
import veilingService.IBiedingService;
import veilingService.IVeilingService;
import veilingService.ServiceProvider;

import com.opensymphony.xwork2.ActionSupport;

public class ShowBiedingen extends ActionSupport {

	List<Bieding> biedingen = new ArrayList<Bieding>();
	private int veilingId;
	IBiedingService ibs = ServiceProvider.getBiedingService();
	IVeilingService ivs = ServiceProvider.getVeilingService();
	Veiling veiling = ivs.getVeilingByID(veilingId);
	
	public String execute(){
		biedingen = ibs.haalBiedingenPerVeilingOp(veilingId);
		return SUCCESS;
	}
	
	public int getVeilingId() {
		return veilingId;
	}
	
	public void setVeilingId(int veilingId) {
		this.veilingId = veilingId;
	}
	
	public List<Bieding> getBiedingen() {
		return biedingen;
	}
	
	public Veiling getVeiling() {
		return veiling;
	}


}
